package com.battery.system.service.battery;

import com.battery.system.domain.BO.MemberBO;
import com.battery.system.domain.Member;
import com.battery.system.domain.VIPDetails;
import com.battery.system.domain.VO.MemberVO;
import com.battery.system.service.IBaseService;

import java.util.List;

/**
 * VIP申请Service接口
 *
 * @author battery
 * @date 2021-01-22
 */
public interface IMemberService extends IBaseService<Member> {
    /**
     * 查询VIP申请
     *
     * @param id VIP申请ID
     * @return VIP申请
     */
    public Member selectMemberById(String id);

    /**
     * 查询VIP申请列表
     *
     * @param member VIP申请
     * @return VIP申请集合
     */
    public List<Member> selectMemberList(Member member);

    /**
     * 新增VIP申请
     *
     * @param member VIP申请
     * @return 结果
     */
    public int insertMember(Member member);

    /**
     * 修改VIP申请
     *
     * @param member VIP申请
     * @return 结果
     */
    public int updateMember(Member member);

    /**
     * 批量删除VIP申请
     *
     * @param ids 需要删除的数据ID
     * @return 结果
     */
    public int deleteMemberByIds(String ids);

    /**
     * 删除VIP申请信息
     *
     * @param id VIP申请ID
     * @return 结果
     */
    public int deleteMemberById(String id);

    /**
     * 查看VIP客户列表
     *
     * @param memberBO
     * @return
     */
    List<MemberVO> selectMemberVOList(MemberBO memberBO);

    List<VIPDetails> selectMemberByKeyList(String id, String key);

    VIPDetails selectVIPDetailsById(String id);

    List<Member> selectMemberOnStoreNameList(Member member);

    /**
     * 校验该用户是否已申请过VIP
     *
     * @param appUserId
     * @return
     */
    Member checkMember(String appUserId);

    /**
     * 查询用户VIP信息
     *
     * @param appUserId
     * @return
     */
    Member selectTrueMember(String appUserId);


    /**
     * 查询该合作商是否存在未审批的vip客户申请
     *
     * @param partnerId
     * @return
     */
    int selectVipInOnCountByPartnerId(String partnerId);
}
